# -*- coding: utf-8 -*-
# @Time    : 2021/4/7 15:01
# @Author  : lilu
# @Email   : 1906196327@qq.com
# @File    : 抽奖系统.py
# @Software: PyCharm


import  random

print("幸运大抽奖！".center(50,"="))

#班级名单
list = ["李璐","李璐","邓军荣","陈姝同","陈柱","戴芙蓉","戴军","段嘉忆","胡天映","李乐豪","罗干"
    ,"彭嘉钰","彭仁杰","夏思毅","胥子珍","姚金池","张仁杰","郑波","蒋才果","熊雪","谭欣"]

#请假人员
leave_name = input("请输入请假的人的名字,名字中间以空格进行区分，没有请假的人请输入0：").split(" ")
#增加人员
add_name = input("请输入增加的人的名字,名字中间以空格进行区分，没有增加的人请输入1：").split(" ")
# print(leave_name,type(leave_name))
while True:
    #需要抽取的人数
    num = int(input("请输入幸运儿的个数："))
    print("-"*50)
    if add_name != ['1']:
        list.extend(add_name)

    if leave_name != ['0']:
        for i in leave_name:
            if i in list:
                list.remove(i)

    # if leave_name == ['0'] and add_name == 1:
    #     print("恭喜今天中奖的同学为：")
    #     for i in range(num):
    #         s = random.randint(0, len(list)-1)
    #         print(list[s])
    #         list.remove(list[s])
    # else:
    print("恭喜今天中奖的同学为：")
    for i in range(num):
        s = random.randint(0,len(list)-1)
        print(list[s])
        list.remove(list[s])

    n = input("****按t退出程序,按a继续程序！")
    if n == "t":
        break
    elif n == "a":
        print("-"*50)
        continue

print("-"*50)
print("程序结束，拜拜》》》》》")
#print(list)

